You are here: Processing Images > Image Filtering > Image Filters and Settings > Thresholding Filters

Thresholding Filters

In digital image processing, thresholding is one of the simplest methods of segmenting images. Basic thresholding methods replace each pixel in an image with a black pixel if the image intensity 'I' is less than some fixed constant 'T', or a white pixel if the image intensity is greater than that constant. In the example below, this results in the lower grayscale values becoming completely black, and higher grayscale values becoming completely white.

Original image (left) and after simple threshold applied (right)

Thresholding example

Thresholding algorithms implemented in Dragonfly can be separated into the following categories:

Simple thresholding… For every pixel, the same threshold value is applied. If the pixel value is smaller than the threshold, it is set to 0, otherwise it is set to a maximum value.

Adaptive thresholding… In cases in which using a global value as a threshold might not be adequate, for example when working with images with varying illumination, adaptive thresholding can be applied. In this case, methods to adapt the threshold value on each pixel to the local image characteristics are applied. This results in a different threshold being selected for each pixel in the image. You should note that adaptive thresholding often requires more computation time than simple thresholding.

If you are not familiar with the details of the different algorithms and the underlying assumptions, it can be difficult to know which algorithm will give the best results. In these cases, experimenting with the different options available will usually result in finding the best algorithm for your purposes.

 

Dragonfly Help Live Version